home *** CD-ROM | disk | FTP | other *** search
/ Mac-Source 1994 July / Mac-Source_July_1994.iso / Other Langs / Tickle-4.0 (tcl) / library / help / tcl / filescan / scancontext next >
Encoding:
Text File  |  1993-10-26  |  1.3 KB  |  26 lines  |  [TEXT/$Tcl]

  1.  
  2.  
  3.           scancontext ?option?
  4.                This command manages file scan contexts.  A  scan  con-
  5.                text  is  a  collection of regular expressions and com-
  6.                mands to execute when that regular expression matches a
  7.                line  of  the  file.   A context may also have a single
  8.                default match, to be applied against lines that do  not
  9.                match  any  of  the regular expressions.  Multiple scan
  10.                contexts may be defined and they may be reused on  mul-
  11.                tiple files.  A scan context is identified by a context
  12.                handle.  The scancontext command  takes  the  following
  13.                forms:
  14.  
  15.           scancontext create
  16.                Create a new scan context.  The  scanmatch  command  is
  17.                used  to define patterns in the context.  A contexthan-
  18.                dle is returned, which the Tcl programmer uses to refer
  19.                to  the  newly created scan context in calls to the Tcl
  20.                file scanning commands.
  21.  
  22.           scancontext delete contexthandle
  23.                Delete the scan context  identified  by  contexthandle,
  24.                and free all of the match statements and compiled regu-
  25.                lar expressions associated with the specified context.
  26.